package Thread;

public class MyThread extends Thread{
    //缺点：已经继承Thread，无法继承其他类，不利于扩展
    @Override
    public void run() {
        for (int i = 0; i < 5; i++) {
            System.out.println(Thread.currentThread().getName()+"输出"+i);
        }
    }


}
